<?php
/**
 * Nordic Repository
 * 
 * LICENSE
 * 
 * The new BSD license is applied on this source-file. For further
 * information please visit http://license.nordic-dev.de/newbsd.txt
 * or send an email to andre.moelle@gmail.com.
 */

/**
 * Necessary includes.
 */
Zend_Loader::loadClass('Zend_Db_Table_Abstract');
Zend_Loader::loadClass('Nordic_Db_Model');

/**
 * Base class for some helpful methods.
 * 
 * Subclassing this class enables your models to attach themselves to
 * the table.
 * 
 * @category   Nordic
 * @package    Nordic_Db
 * @copyright  2007 Nordic Development
 * @license    http://license.nordic-dev.de/newbsd.txt (New-BSD license)
 * @author     Andre Moelle <andre.moelle@gmail.com>
 * @version    $Id: Table.php 3 2007-07-08 09:21:42Z andre.moelle $
 */
class Nordic_Db_Table extends Zend_Db_Table_Abstract
{
	/**
	 * Instance of a model-object.
	 * 
	 * @var Nordic_Db_Model
	 */
	protected $_model;
	
	/**
	 * Returns the set model.
	 * 
	 * @param void
	 * @return Nordic_Db_Model
	 */
	public function getModel ()
	{
		return $this->_model;
	}
	
	/**
	 * Sets the model which attached this table.
	 * 
	 * @param Nordic_Db_Model $model instance of a model
	 * @return void
	 */
	public function setModel (Nordic_Db_Model $model)
	{
		$this->_model = $model;
	}
}
?>